import 'package:flutter/material.dart';

class QrScanner extends StatefulWidget {
  @override
  _QrScannerState createState() => _QrScannerState();
}

class _QrScannerState extends State<QrScanner> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('二维码扫描'),
      ),
      body: Column(
        children: <Widget>[
          RaisedButton(
            child: Text('扫一扫'),
            onPressed: () async {
//              var result = await BarcodeScanner.scan();
//              print(result.format);
//              print(result.formatNote);
//              print(result.rawContent);
//              print(result.type);
            },
          )
        ],
      ),
    );
  }
}
